<?php

namespace app\models;

use Yii;

/**
 * This is the model class for table "t_forum_user_browsing_history".
 *
 * @property string $id
 * @property string $topic_id 浏览的主题
 * @property string $hits 点击量
 * @property string $create_time
 * @property string $del_flag
 */
class TForumUserBrowsingHistory extends \yii\db\ActiveRecord
{
    /**
     * @inheritdoc
     */
    public static function tableName()
    {
        return 't_forum_user_browsing_history';
    }

    /**
     * @inheritdoc
     */
    public function rules()
    {
        return [
            [['id', 'hits', 'create_time', 'del_flag'], 'required'],
            [['hits'], 'integer'],
            [['create_time'], 'safe'],
            [['id', 'topic_id'], 'string', 'max' => 36],
            [['del_flag'], 'integer', 'max' => 1],
            [['id'], 'unique'],
        ];
    }

    /**
     * @inheritdoc
     */
    public function attributeLabels()
    {
        return [
            'id' => 'ID',
            'topic_id' => 'Topic ID',
            'hits' => 'Hits',
            'create_time' => 'Create Time',
            'del_flag' => 'Del Flag',
        ];
    }
}
